package cn.wzy.service;

import cn.wzy.common.Result;

import java.util.Map;

/**
 * @author nihaowzy
 * @date 2020/12/24 11:55
 */
public interface CustomerService {
    /**
     * 查询客户信息
     * @param params
     * @param page
     * @param limit
     * @return
     */
     Result queryPage(Map<String,String> params , Integer page , Integer limit) throws Exception;


    /**
     * 添加客户信息
     * @param name
     * @param phone
     * @param sex
     * @param company
     * @param userId
     * @return
     */
    Result addCustomer(String name ,String phone ,Integer sex ,String company , Integer userId) throws Exception;

    /**
     * 根据id修改客户信息
     * @param name
     * @param phone
     * @param sex
     * @param company
     * @param id
     * @return
     */
    Result updateCustomer(String name ,String phone ,Integer sex ,String company , Integer id) throws Exception;


    /**
     * 根据客户id将客户的状态改为无效
     * @param id
     * @return
     * @throws Exception
     */
    Result deleteCustomer(Integer id) throws Exception;

    /**
     * 批量修改客户的业务员
     * @param userId
     * @param cIds
     * @return
     * @throws Exception
     */
    Result batchSalesMan(String  userId , String[] cIds) throws Exception;


    /**
     * 新增拜访记录
     * @param customerId
     * @param customerName
     * @param userId
     * @param realname
     * @param visitTime
     * @param descp
     * @return
     * @throws Exception
     */
    Result addVisitLog(String customerId, String customerName, Integer userId, String realname, String visitTime, String descp) throws Exception;
}
